package com.ruoyi.crm.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.crm.mapper.CrmVisitObjectivesMapper;
import com.ruoyi.crm.domain.CrmVisitObjectives;
import com.ruoyi.crm.service.ICrmVisitObjectivesService;

/**
 * 拜访目标Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-01-29
 */
@Service
public class CrmVisitObjectivesServiceImpl implements ICrmVisitObjectivesService 
{
    @Autowired
    private CrmVisitObjectivesMapper crmVisitObjectivesMapper;

    /**
     * 查询拜访目标
     * 
     * @param visitObjectivesId 拜访目标主键
     * @return 拜访目标
     */
    @Override
    public CrmVisitObjectives selectCrmVisitObjectivesByVisitObjectivesId(Long visitObjectivesId)
    {
        return crmVisitObjectivesMapper.selectCrmVisitObjectivesByVisitObjectivesId(visitObjectivesId);
    }

    /**
     * 查询拜访目标列表
     * 
     * @param crmVisitObjectives 拜访目标
     * @return 拜访目标
     */
    @Override
    public List<CrmVisitObjectives> selectCrmVisitObjectivesList(CrmVisitObjectives crmVisitObjectives)
    {
        return crmVisitObjectivesMapper.selectCrmVisitObjectivesList(crmVisitObjectives);
    }

    /**
     * 新增拜访目标
     * 
     * @param crmVisitObjectives 拜访目标
     * @return 结果
     */
    @Override
    public int insertCrmVisitObjectives(CrmVisitObjectives crmVisitObjectives)
    {
        return crmVisitObjectivesMapper.insertCrmVisitObjectives(crmVisitObjectives);
    }

    /**
     * 修改拜访目标
     * 
     * @param crmVisitObjectives 拜访目标
     * @return 结果
     */
    @Override
    public int updateCrmVisitObjectives(CrmVisitObjectives crmVisitObjectives)
    {
        return crmVisitObjectivesMapper.updateCrmVisitObjectives(crmVisitObjectives);
    }

    /**
     * 批量删除拜访目标
     * 
     * @param visitObjectivesIds 需要删除的拜访目标主键
     * @return 结果
     */
    @Override
    public int deleteCrmVisitObjectivesByVisitObjectivesIds(Long[] visitObjectivesIds)
    {
        return crmVisitObjectivesMapper.deleteCrmVisitObjectivesByVisitObjectivesIds(visitObjectivesIds);
    }

    /**
     * 删除拜访目标信息
     * 
     * @param visitObjectivesId 拜访目标主键
     * @return 结果
     */
    @Override
    public int deleteCrmVisitObjectivesByVisitObjectivesId(Long visitObjectivesId)
    {
        return crmVisitObjectivesMapper.deleteCrmVisitObjectivesByVisitObjectivesId(visitObjectivesId);
    }
}
